#include <cstdio>

bool Fun1(const char* str)
{
	printf("%s\n",str);
	return false;
}

bool Fun2(const char* str)
{
	printf("%s\n",str);
	return true;
}

int main(int argc, char* argv[])
{
	bool res1, res2;
	res1 = (Fun1("a") && Fun2("b")) || (Fun1("c") || Fun2("d"));
	res2 = (Fun1("a") && Fun2("b")) && (Fun1("c") || Fun2("d"));

	printf("res1 = %d, res2 = %d\n", res1,res2);
	printf("res1 || res2 = %d\n", res1 || res2);
	return res1 || res2;
}
